# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'httpWidget.ui'
#
# Created: Sat Dec  6 17:47:32 2008
#	  by: PyQt4 UI code generator 4.4.4
#
# WARNING! All changes made in this file will be lost!

from PyQt4 import QtCore, QtGui, QtWebKit

class Ui_HttpWidget(object):

	def setupUi(self, HttpWidget):
		HttpWidget.setObjectName("HttpWidget")
		HttpWidget.resize(636, 336)
		self.verticalLayout = QtGui.QVBoxLayout(HttpWidget)
		self.verticalLayout.setObjectName("verticalLayout")
		self.horizontalLayout = QtGui.QHBoxLayout()
		self.horizontalLayout.setObjectName("horizontalLayout")
		self.back = QtGui.QPushButton(HttpWidget)
		icon = QtGui.QIcon()
		icon.addPixmap(QtGui.QPixmap("gui\\icons\\back.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
		self.back.setIcon(icon)
		self.horizontalLayout.addWidget(self.back)
		self.next = QtGui.QPushButton(HttpWidget)
		self.next.setEnabled(True)
		self.next.setLayoutDirection(QtCore.Qt.RightToLeft)
		icon1 = QtGui.QIcon()
		icon1.addPixmap(QtGui.QPixmap("gui\\icons\\next.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
		self.next.setIcon(icon1)
		self.horizontalLayout.addWidget(self.next)
		self.stop = QtGui.QPushButton(HttpWidget)
		icon2 = QtGui.QIcon()
		icon2.addPixmap(QtGui.QPixmap("gui\\icons\\stop.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
		self.stop.setIcon(icon2)
		self.horizontalLayout.addWidget(self.stop)
		self.reload = QtGui.QPushButton(HttpWidget)
		icon3 = QtGui.QIcon()
		icon3.addPixmap(QtGui.QPixmap("gui\\icons\\reload.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
		self.reload.setIcon(icon3)
		self.horizontalLayout.addWidget(self.reload)
		self.home = QtGui.QPushButton("Home", HttpWidget)
		#icon
		self.horizontalLayout.addWidget(self.home)
		#cytoscape button
		self.cytoscape = QtGui.QPushButton("Cytoscape", HttpWidget)
		icon4 = QtGui.QIcon()
		icon4.addPixmap(QtGui.QPixmap("gui\\icons\\cytoscape.jpeg"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
		self.cytoscape.setIcon(icon4)
		self.horizontalLayout.addWidget(self.cytoscape)
		
		self.url = QtGui.QLineEdit(HttpWidget)
		self.url.setObjectName("url")
		self.horizontalLayout.addWidget(self.url)
		self.verticalLayout.addLayout(self.horizontalLayout)
		
		self.tab_widget = QtGui.QTabWidget()
		self.tab_widget.setTabsClosable(True)
		
		self.tab = WebTab(self.tab_widget)
		self.tab_widget.addTab(self.tab, self.tab.webview.url().toString())
		
		self.verticalLayout.addWidget(self.tab_widget)
		
		self.retranslateUi(HttpWidget)
		QtCore.QMetaObject.connectSlotsByName(HttpWidget)

	def retranslateUi(self, HttpWidget):
		HttpWidget.setWindowTitle(QtGui.QApplication.translate("HttpWidget", "Webyo", None, QtGui.QApplication.UnicodeUTF8))
		self.back.setToolTip(QtGui.QApplication.translate("HttpWidget", "Back", None, QtGui.QApplication.UnicodeUTF8))
		self.back.setText(QtGui.QApplication.translate("HttpWidget", "Back", None, QtGui.QApplication.UnicodeUTF8))
		self.next.setToolTip(QtGui.QApplication.translate("HttpWidget", "Next", None, QtGui.QApplication.UnicodeUTF8))
		self.next.setText(QtGui.QApplication.translate("HttpWidget", "Next", None, QtGui.QApplication.UnicodeUTF8))
		self.stop.setToolTip(QtGui.QApplication.translate("HttpWidget", "Stop", None, QtGui.QApplication.UnicodeUTF8))
		self.stop.setText(QtGui.QApplication.translate("HttpWidget", "Stop", None, QtGui.QApplication.UnicodeUTF8))
		self.reload.setToolTip(QtGui.QApplication.translate("HttpWidget", "Reload", None, QtGui.QApplication.UnicodeUTF8))
		self.reload.setText(QtGui.QApplication.translate("HttpWidget", "Reload", None, QtGui.QApplication.UnicodeUTF8))

class WebTab(QtGui.QWidget):
	"""
	class for handling tab
	"""
	def __init__(self,  parent =None):
		"""Constructor"""
		
		QtGui.QWidget.__init__(self, parent)
		self.vb = QtGui.QVBoxLayout()
		
		self.webview = QtWebKit.QWebView()
		self.true_url =QtCore.QUrl("http://www.google.fr")
		self.webview.setUrl(self.true_url)
		
		self.vb.addWidget(self.webview)
		self.setLayout(self.vb)

	
	
	
	
	
	
	
	
	
	
	
